#pragma once
#include "export.h"
#include "RenderEngineSystem.h"

class Render : public Apo::RenderEngineSystem ,public  Ogre::FrameListener
{
public:
	Render(void);
	~Render(void);
	//init ogre
	virtual void   start(HWND phWnd,unsigned int width, unsigned int height,void * p=NULL) ;
	virtual void   stop() ;
	virtual  char* getName() {return "OgreRender";}
	virtual void   updata(float time);
	virtual bool   frameStarted(const FrameEvent& evt);

protected:
	void		   SetupOgre(HWND phWnd,unsigned int width, unsigned int height);
	Ogre::Root			*m_OgreRoot;
	Ogre::RenderWindow	*m_Window;
	Ogre::SceneManager	*m_SceneManager;
};

extern "C" void PluginExport dllStartPlugin(void);

extern "C" void PluginExport dllStopPlugin(void);
